<?php

namespace app\member\controller;

use app\common\controller\Frontend;

class member extends Frontend
{

    protected $noNeedLogin = '*';
    protected $noNeedRight = '*';
    protected $layout = '';

    public function index()
    {
        if(session('memberinfo')){
            $this->error("请去登录",'member/login/index');
        }
        $member=session('memberinfo');
        //var_dump(session('memberinfo'));
        $memberinfo=MemberModel::where('id',$member->id)->find();
        $this->assign("member",$memberinfo);

        return $this->view->fetch();
    }


}
